<?php
/**
 * 横幅验证器模型
 * @Author: 聂哥
 * @Date: 2022-11-26 14:51:23
*/

namespace app\admin\validate;

use think\Validate;

class Category extends Validate
{
    protected $rule =   [
        'name'  => 'require',  
        'admin_id'  => 'require',  
        'intro'  => 'require',  
        'status'  => 'require', 
    ];
    
    protected $message  =   [
        'name.require' => '分类名不能为空',
        'admin_id.require' => '作者不能为空',
        'intro.require' => '资讯内容不能为空',
		'status.require' => '状态不能为空'
    ];
	
	protected $scene = [
        'add'  =>  ['name','admin_id','intro','status'],
    ];
    
}